package com.example.dormitorymanagement.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author admin
 * @since 2021-06-04
 */
@ApiModel(value = "维修对象")
public class Service implements Serializable {

    private static final long serialVersionUID=1L;

    @ApiModelProperty(name = "id",value = "数据库自增id，前端一般不用传值")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(name = "building",value = "表示第几栋")
    private Integer building;

    @ApiModelProperty(name = "number",value = "表示宿舍的编号")
    private Integer number;

    @ApiModelProperty(name = "report",value = "报修人的名字")
    private String report;

    @ApiModelProperty(name = "phone",value = "报修人的电话")
    private String phone;

    @ApiModelProperty(name = "reason",value = "报修理由")
    private String reason;

    @TableField("Reportingtime")
    @ApiModelProperty(name = "Reportingtime",value = "报修时间")
    private LocalDateTime Reportingtime;

    @ApiModelProperty(name = "status",value = "状态，为0则表示未解决，为1则表示已解决")
    private Integer status;

    @ApiModelProperty(name = "resolutiontime",value = "解决的时间")
    private LocalDateTime resolutiontime;

    public Service()
    {
        this.Reportingtime = LocalDateTime.now();

        this.resolutiontime = null;

        this.status = 0;
    }
    
    public Integer getId() {
        return id;
    }

      public void setId(Integer id) {
          this.id = id;
      }
    
    public Integer getBuilding() {
        return building;
    }

      public void setBuilding(Integer building) {
          this.building = building;
      }
    
    public Integer getNumber() {
        return number;
    }

      public void setNumber(Integer number) {
          this.number = number;
      }
    
    public String getReport() {
        return report;
    }

      public void setReport(String report) {
          this.report = report;
      }
    
    public String getPhone() {
        return phone;
    }

      public void setPhone(String phone) {
          this.phone = phone;
      }
    
    public String getReason() {
        return reason;
    }

      public void setReason(String reason) {
          this.reason = reason;
      }
    
    public LocalDateTime getReportingtime() {
        return Reportingtime;
    }

      public void setReportingtime(LocalDateTime Reportingtime) {
          this.Reportingtime = Reportingtime;
      }
    
    public Integer getStatus() {
        return status;
    }

      public void setStatus(Integer status) {
          this.status = status;
      }
    
    public LocalDateTime getResolutiontime() {
        return resolutiontime;
    }

      public void setResolutiontime(LocalDateTime resolutiontime) {
          this.resolutiontime = resolutiontime;
      }

    @Override
    public String toString() {
        return "Service{" +
              "id=" + id +
                  ", building=" + building +
                  ", number=" + number +
                  ", report=" + report +
                  ", phone=" + phone +
                  ", reason=" + reason +
                  ", Reportingtime=" + Reportingtime +
                  ", status=" + status +
                  ", resolutiontime=" + resolutiontime +
              "}";
    }
}
